package com.sigmatrix.h5.enums;

import java.util.ArrayList;
import java.util.List;

/**
 * 
 *@ClassName: ScanType
 *@Description: 扫码类型
 *@author MH
 *@date 2017年12月6日 下午1:30:11
 */
@SuppressWarnings("serial")
public enum ScanType {

	/**
	 * 层级扫码
	 */
	HIERARCHY(Short.valueOf("2"),Type.hierarchyType,"层级扫码"),

	/**
	 * 终端扫码
	 */
	TERMINAL(Short.valueOf("1"),Type.terminalType,"终端扫码");

	public Short value;
	
	private ScanType(Short value, List<Short> conditionType, String name) {
		this.value = value;
		this.conditionType = conditionType;
		this.name = name;
	}

	public List<Short> conditionType;
	
	public String name;
	
	static class Type{
		private static List<Short> hierarchyType = new ArrayList<Short>(){{
			add(ConditionType.FIRST_SCAN_TYPE.value);
			}
		};
		private static List<Short> terminalType = new ArrayList<Short>(){{
			add(ConditionType.WRITE_BACK_DEALER_COUNT.value);
			add(ConditionType.NEW_SHOP_SCAN_TIME_IN_HOURE.value);
		}
		};
	}
}
